<?php

namespace App\Http\Controllers\Backstage;

use App\Ant\WithUpload;
use App\Http\Controllers\BaseController;
use App\Http\Requests\Backstage\UploadRequest;
use App\Transformers\MediaTransformer;
use Intervention\Image\ImageManager;

class UploadController extends BaseController
{
    use WithUpload;

    public function upload(UploadRequest $request)
    {
        $model = $this->addUpload($request);
        return $this->response->item($model, new MediaTransformer());
    }
}
